package cn.huiyunche.base.service.enums;

/**
 * Created by LYN on 6/18/16.
 */
public enum ProjectEnum {

    KYLE("kyle", "KYLE"),
    KYLEBUSS("kylebuss", "KYLEBUSS"),
    STAN("stan", "STAN"),
    STANBUSS("stanbuss", "STANBUSS"),
    STANCITY("stancity", "STANCITY"),
    STANBUSSCITY("stanbusscity", "STANBUSSCITY"),
    DRIVER("driver", "DRIVER"),
    SUPPLIER("supplier", "SUPPLIER");

    private final String value;
    private final String text;

    ProjectEnum(String value, String text) {
        this.value = value;
        this.text = text;
    }

    public String getValue() {
        return value;
    }

    public String getText() {
        return text;
    }

    public static ProjectEnum getByValue(int value) {
        for (ProjectEnum temp : ProjectEnum.values()) {
            if (temp.getValue().equals(value)) {
                return temp;
            }
        }
        return null;
    }
}
